package com.star.carservice.client.activity.base;

import com.star.carservice.R;
import com.star.carservice.client.activity.RegisterActivity;

import android.content.Context;
import android.content.Intent;
import android.os.Bundle;
import android.support.v4.app.Fragment;

public abstract class BaseSingleFragmentActivity extends BaseActivity {

	public abstract Fragment getFragment();

	@Override
	protected void onCreate(Bundle savedInstanceState) {

		super.onCreate(savedInstanceState);

		setContentView(R.layout.activity_placeholder);

		if (savedInstanceState == null) {
			getSupportFragmentManager().beginTransaction()
					.replace(R.id.view_placeholder, getFragment()).commit();
		}
	}

}
